import {Component } from 'react'
import { Layout } from 'antd';
import './set.css'
import {Link} from 'react-router-dom'
const { Sider, Content } = Layout;
class BasicSet extends Component{
    state={
        isactive:'basic'
    }
    render() {
        return(
            <div className='contanir'>
                <Layout>
                    {/*左边栏*/}
                    <Sider className='setSider'>
                        <div className={['setSiderCont',this.state.isactive=='basic'?'active':null].join(' ')} onClick={()=>{this.setState({isactive:'basic'})}}><Link to='/basicset/basicsetchild' className={this.state.isactive=='basic'?'white':null}>基本设置</Link></div>
                        <div className={['setSiderCont',this.state.isactive=='safe'?'active':null].join(' ')} onClick={()=>{this.setState({isactive:'safe'})}}><Link to='/basicset/safetyset' className={this.state.isactive=='basic'?'white':null}>安全设置</Link></div>
                        <div className={['setSiderCont',this.state.isactive=='account'?'active':null].join(' ')} onClick={()=>{this.setState({isactive:'account'})}}><Link to='/basicset/accountset' className={this.state.isactive=='basic'?'white':null}>账号绑定</Link></div>
                    </Sider>
                    {/*右边栏*/}
                    <Content className='setContent'>
                        {this.props.children}
                    </Content>
                </Layout>
                </div>
        )
    }
}
export default BasicSet